package controller;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import pojo.User;
import service.UserService;

@Controller
public class UserController {
    @Autowired
    private UserService userService;
    @RequestMapping("/findUser")
    public String findUser(String username)
    {
        System.out.println(username);
        User user1 = userService.findUser(username);
        System.out.println(user1);
        return "index.jsp";
    }
}
